#ifndef LED_H
#define LED_H
#include <string>
#include "send.h"
using namespace std;
//! An object to control a robot LED
class LED {
    private:
	//! specifies which LED the object will control
        int port;
	//! specifies whether the LED is on or not
        bool isOn;
    public:
	//! legal LED port values
	//! int value for any an LED set to this will do nothing
        static const int ANY   = 0;
	//! int value for red
        static const int RED   = 1;
	//! int value for green
        static const int GREEN = 2;
	//! int value for blue
        static const int BLUE  = 3;
	//! string value for any
        static const string ANY_STR;   // = "ANY";
	//! string value for red
        static const string RED_STR;   // = "RED";
	//! string value for green
        static const string GREEN_STR; // = "GREEN";
	//! string value for blue
        static const string BLUE_STR;  // = "BLUE";
	/*! Constructor takes initializes port to a legal port parameter ranging 1-3
	 * \param pt selects which LED the LED will control red, green, or blue 
	 */ 
        LED(int pt);
	/*! turn LED on or off according to a boolean value
	 * \param isOn turns LED on if true and off if false
	 */
        void setLED(bool isOn);
	//! returns bool true for on false for off
        bool getIsOn();
	//! returns an int corresponding to the color of the LED
        int getColor();
	/*! returns int corresponding to the string 
	 * \return LED::ANY for strings which are not equal to one of the LED color strings
	 */ 
        static int colorStringToInt(string s);
	/*! returns string corresponding to the int 
	 * \return LED::ANY_STR for ints which are not equal to one of the LED color ints
	 */ 
        static string intToColorString(int color);
};

#endif
